﻿function Wasp(point, name) {
	this.init(point, name);
    this.moveAmount = Wasp.baseMoveAmount;
    this.smallMarker = new GMarker(this._curPoint, { icon: Wasp.smallMapIcon, zIndexProcess: function(){return -50;} });
    this.setMarkerStanding();
}
Wasp.inheritsFrom(Creature);

//Static properties
if(!DEBUG)Wasp.baseMoveAmount = .00008; else Wasp.baseMoveAmount = .0002; 
Wasp.maxHealth = 2;
Wasp.value = 1; //Value of killing
Wasp.damagePower = 1;

//Must use a function for this to create unique gif names
Wasp.getDeathIcon = function(){
	var deadIcon = new GIcon(G_DEFAULT_ICON);
	deadIcon.shadow = "";
	deadIcon.image = "http://labs.ribaudio.com/herosquad/img/v2/waspdie.gif?" + (++Creature.uniqueCount);
	deadIcon.iconSize = new GSize(45, 63);
	deadIcon.iconAnchor = new GPoint(22, 51);
	return deadIcon;
}

//Static icon properties
var smallMapIcon = new GIcon(G_DEFAULT_ICON);
smallMapIcon.image = "http://labs.ribaudio.com/herosquad/img/v2/waspmarker.png";
smallMapIcon.shadow = "";
smallMapIcon.iconSize = new GSize(20, 20);
smallMapIcon.iconAnchor = new GPoint(10, 10);
Wasp.smallMapIcon = smallMapIcon;

var standingIcon = new GIcon(G_DEFAULT_ICON);
standingIcon.shadow = "http://labs.ribaudio.com/herosquad/img/v2/waspstand.png";
standingIcon.shadowSize = new GSize(45, 63);
standingIcon.image = Creature.imgHealth100;
standingIcon.iconSize = new GSize(45, 63);
standingIcon.iconAnchor = new GPoint(22, 51);
Wasp.standingIcon = standingIcon;

var walkingIcon = new GIcon(G_DEFAULT_ICON);
walkingIcon.shadow = "http://labs.ribaudio.com/herosquad/img/v2/waspwalk.gif";
walkingIcon.shadowSize = new GSize(45, 63);
walkingIcon.image = Creature.imgHealth100;
walkingIcon.iconSize = new GSize(45, 63);
walkingIcon.iconAnchor = new GPoint(22, 51);
Wasp.walkingIcon = walkingIcon;

//Instance methods
Wasp.prototype.performActionAtTarget = function() {
    this.onExploded.fire();
}